# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=kea-hook-userchk-ldap
pkgver=0.1.0
pkgrel=3
pkgdesc="Kea DHCP hook for checking user access in LDAP"
url="https://github.com/cvut/kea-hook-userchk-ldap/"
arch="all !armhf !armv7 !s390x"  # limited by kea
license="MPL-2.0"
makedepends="autoconf automake kea-dev libtool openldap-dev boost-dev log4cplus-dev"
source="https://github.com/cvut/kea-hook-userchk-ldap/archive/v$pkgver/$pkgname-$pkgver.tar.gz"
builddir="$srcdir/$pkgname-$pkgver"
options="!check"  # no tests provided

prepare() {
	default_prepare
	./autogen.sh
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--enable-generate-messages \
		--disable-static
	make
}

package() {
	make install DESTDIR="$pkgdir"
}

sha512sums="917a85de814c263fc794d48595c616d97d8e61d70dfd80a0f44379515fc1f0d72734d30e6de7b833f046c5842b87946e57d7c068814f7154ed210f2ceb4efb58  kea-hook-userchk-ldap-0.1.0.tar.gz"
